package com.just.bz_back.model.dto;

/**
 * 内存使用状况
 */
public class MonitorInfoBean {
    /** 可使用内存. */
    private long totalMemory;

    /** 剩余内存. */
    private long freeMemory;

    /** 最大可使用内存. */
    private long maxMemory;

    /** 内存使用率  */
    private long memoryRatio;

    @Override
    public String toString() {
        return "内存使用状况：" +
                "totalMemory=" + totalMemory +"M" +
                ", freeMemory=" + freeMemory +"M" +
                ", maxMemory=" + maxMemory +"M" +
                ", memoryRatio=" + memoryRatio / 100 + "%" +
                '！';
    }

    public MonitorInfoBean(long totalMemory, long freeMemory, long maxMemory, long memoryRatio) {
        this.totalMemory = totalMemory;
        this.freeMemory = freeMemory;
        this.maxMemory = maxMemory;
        this.memoryRatio = memoryRatio;
    }

    public long getTotalMemory() {
        return totalMemory;
    }

    public void setTotalMemory(long totalMemory) {
        this.totalMemory = totalMemory;
    }

    public long getFreeMemory() {
        return freeMemory;
    }

    public void setFreeMemory(long freeMemory) {
        this.freeMemory = freeMemory;
    }

    public long getMaxMemory() {
        return maxMemory;
    }

    public void setMaxMemory(long maxMemory) {
        this.maxMemory = maxMemory;
    }

    public long getMemoryRatio() {
        return memoryRatio;
    }

    public void setMemoryRatio(long memoryRatio) {
        this.memoryRatio = memoryRatio;
    }
}
